Why Version Control?

Here's why.


In [1]:
from IPython.display import Image
Image(url='http://www.phdcomics.com/comics/archive/phd101212s.gif')


Out[1]:

If that hasn't convinced you, here are some other benefits:

http://stackoverflow.com/questions/1408450/why-should-i-use-version-control

Replace 'code' in the first answer with 'essay', 'thesis', 'homework' -- all stuff that a version control system such as git and GitHub can help you with!

Git for Scientists: A Tutorial (by John McDonnell)

http://nyuccl.org/pages/GitTutorial/

Go through the tutorial. You can either follow along from the terminal in the command line, or from within this very notebook using the %%bash magic:


In [1]:
%%bash
git status


# On branch master
# Your branch is ahead of 'origin/master' by 4 commits.
#
# Changes not staged for commit:
#   (use "git add <file>..." to update what will be committed)
#   (use "git checkout -- <file>..." to discard changes in working directory)
#
#	modified:   ../Syllabus and Reading List.ipynb
#	modified:   Version Control.ipynb
#
# Untracked files:
#   (use "git add <file>..." to include in what will be committed)
#
#	../.ipynb_checkpoints/
#	.ipynb_checkpoints/
no changes added to commit (use "git add" and/or "git commit -a")

Starting a codeblock in the notebook environment with the magic phrase %%bash allows you to run terminal commands from within a notebook (more on that in the next section!)


In [ ]: